<template>
  <el-result icon="warning" title="404" sub-title="对不起，您访问的页面不存在。">
    <template #extra>
      <el-button type="primary" @click="goHome">返回首页</el-button>
    </template>
  </el-result>
</template>

<script>
import { useRouter } from 'vue-router';

export default {
  name: 'NotFound',
  setup() {
    const router = useRouter()

    const goHome = () => {
      router.push('/home')
    }

    return {
      goHome,
    }
  }
}
</script>

<style scoped>
.el-result {
  margin-top: 50px;
  text-align: center;
}
</style>
